package com.springbootweb.client;

import com.springbootsys.entity.User;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.security.core.Authentication;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(qualifier = "sysUserClient", name = "springboot-sys",path = "/user")
public interface SysUserClient{
    @PostMapping("getUserInfo")
    User getUserInfo(@RequestBody User user);
    @GetMapping("loadUserByUsername")
    User loadUserByUsername(@RequestParam("s") String s);
    @GetMapping("getAllUsers")
    List<User> getAllUsers();
}
